Recent advances in computer performance have enabled graphic systems to provide more realistic graphical images using personal computers and home video game computers. In such graphic systems, some procedure must be implemented to “render” or draw graphic primitives to the screen of the system. A “graphic primitive” is a basic component of a graphic picture, such as a polygon, e.g., a triangle, or a vector. All graphic pictures are formed with combinations of these graphic primitives. Many procedures may be utilized to perform graphic primitive rendering.
Early graphic systems displayed images representing objects having extremely smooth surfaces. That is, textures, bumps, scratches, or other surface features were not modeled. In order to improve the quality of the image, texture mapping was developed to model the complexity of real world surface images. In general, texture mapping is the mapping of an image or a function onto a surface in three dimensions.
With the early graphic systems, textures on surfaces consisted of color information only. For example, the texture would be a picture of whatever material the designer was trying to convey (e.g., brick, stone, vegetation, wood, etc.) and would contain shading information as well as the texture and color to create the impression of a complex, dimensional surface. In more recent graphic systems, a light map is often combined with the color map to create a more realistic sense of shading and soft shadowing. The trouble with this technique is that the shading on a particular texture would often be at variance with the perceived sources of light in the scene in which they were used. For example, a texture might be drawn as if it were lit from the upper left, but in a particular scene, the actual light source may be from the right, or below the texture.
To overcome these limitations, a new technique was developed, generically called “bump mapping”. In its simplest form, a texture on a surface contains two textures, for example, a color map and a second map that contains the height information for the surface. This information enables the rendering of highlights and shadows on the surface according to where the lights in the scene are located, resulting in a vastly improved surface realism. The problem with prior art bump mapping techniques is the fact that the graphic system is restricted to portraying transitions in elevation only, resulting in a flattened appearance of the actual height information the designer is trying to convey.
Normal maps were developed to overcome the limitations of bump mapping. While a height map only contains 1 component of information (e.g., the “Z” height or direction), the vectors of a normal map contains 3 components of information (e.g., “X” direction, “Y” direction and “Z” direction). Thus, each pixel in a normal map encodes which direction that particular point is facing (e.g., the “normal vector” of the surface). Each pixel in a normal map has meaningful information, so details can be rendered more crisply than with bump maps alone.
The problem with real-time rendering using normal maps is that there is an excessively large amount of data to manipulate for each rendered frame. For example, normal maps typically use three channels of information in their coding, mapped to a standard RGB image. Generally, for each pixel, the red channel can be used to encode normal vectors in the X direction. Similarly, the green channel encodes normal vectors in the Y direction, and the blue channel encodes normal vectors in the Z direction, or the like.
To improve the performance of real-time rendering graphics systems, several prior art normal map compression schemes have been developed. The objective of these prior art compression schemes is to compress normal maps (e.g., texture maps where each pixel is a normalized vector) so that their storage consumes less space and their processing consumes less bandwidth.
One prior art compression scheme uses a hemispherical normal map data structure, where 16 bits per pixel were used to represent any point on a hemisphere. In a typical case, 65,536 points on the surface of the hemisphere would each be described by a respective 16 bits. Thus, the normal for any point on the surface would be described by selecting its corresponding normal, or point, on the hemisphere data structure. A significant degree of compression can be obtained with this prior art compression scheme. The compression results in some degree of quantization loss.
The problem with this prior art compression scheme, however, is that there still remains a very large amount of data that must be manipulated and processed in real-time. This large amount of data still presents a significant burden on even the most modern graphics rendering pipelines.